﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Text;
using System.Threading.Tasks;

namespace TestAspMail
{
    class Program
    {
        static void Main(string[] args)
        {
            string SmtpServer = "CLUSTER2OUT.AP.MESSAGELABS.COM";
            string SmtpUsername = "notifybot";
            string SmtpPassword = "xxxxx";
            string SenderEmail = "notifybot@kepland.com";
            string SenderName = "Ali Baba 7";

            ASPEMAILLib.IMailSender objMail = new ASPEMAILLib.MailSender();
            objMail = new ASPEMAILLib.MailSender();
            objMail.Host = SmtpServer;
            //objMail.Username = SmtpUsername;
            //objMail.Password = SmtpPassword;
            objMail.From = SenderEmail;
            objMail.FromName = SenderName;


            objMail.AddAddress("zhixian.ong@kepland.com.sg");
            objMail.CharSet = "UTF-8";
            objMail.ContentTransferEncoding = "Quoted-Printable";
            objMail.Subject = objMail.EncodeHeader("Hello world test", "UTF-8");
            objMail.Body = "hello world" + DateTime.Now.ToString();
            objMail.IsHTML = 1;
            objMail.Queue = 1;
            objMail.Send(@"C:\AspMail");
            
            
            
        }
    }
}
